<html>
<head>

<style type="text/css">
	div#txt {
		width:10px;
		height:10px;
		background-color:red;
		position:relative;
	}
	
	div#txt:hover {
		background-color:yellow;
	}
</style>

<script type="text/javascript">
	var x = 5;
	var y = 5;
	var ux = true;
	var uy = true;
	
function startTime() {
	if ( ux )
		if ( x >= 195 )
			ux = false;
		else 
			x++;
	else
		if ( x < 0 )
			ux = true;
		else 
			x--;

	if ( uy )
		if ( y >= 131 )
			uy = false;
		else
			y++;
	else
		if ( y < 0 )
			uy = true;
		else
			y--;
			
	document.getElementById('txt').style.top = y + "px";
	document.getElementById('txt').style.left = x + "px";
	setTimeout('startTime()', 7);
}

</script>
</head>
<body onload="startTime()">
<div id="outer" style="border:solid 1; width:200px; height:136px">

	<div id="txt"></div>

</div>
<div id="asdf"></div>
</body>
</html>
